<template>
	<div class="page-census page-setting">
		<el-container :style="{height: mainH+'px'}">
		  	<el-aside class="setting-nav-wrap" width="200px">
		  		<ul class="setting-nav">
		  			<router-link tag="li" :to="item.path" :class="{active:$route.path==item.path}" v-for="(item,index) in navList" :key="index"><i :class="'iconfont '+item.icon"></i> {{item.name}}</router-link>
		  		</ul>
		  	</el-aside>
		  	<el-main class="setting-main">
		  		<keep-alive>
					<router-view :winH="winH" v-if="$route.meta.keepAlive"></router-view>
				</keep-alive>
				<router-view :winH="winH" v-if="!$route.meta.keepAlive"></router-view>
		  	</el-main>
		</el-container>
	</div>
</template>
<script>
export default {
	name: 'Archive',
	components:{},
	props: {
		winH: {
			type: Number,
			default: 500
		}
	},
	data () {
		return {
			navList: [{
				name: '企业概览',
				icon: 'icon-company',
				path: '/archive'
			},{
				name: '企业单位档案',
				icon: 'icon-record',
				path: '/archiveRecord'
			},{
				name: '巡检点维护',
				icon: 'icon-inspect',
				path: '/archiveInspect'
			},{
				name: '单位平面图',
				icon: 'icon-plat',
				path: '/archivePlat'
			},{
				name: '消防合法文书',
				icon: 'icon-record',
				path: '/archiveDocument'
			},{
				name: '现场记录',
				icon: 'icon-rule',
				path: '/picture'
			},{
				name: '消防预案和演练',
				icon: 'icon-plan',
				path: '/archivePlan'
			},{
				name: '消防培训',
				icon: 'icon-train',
				path: '/archiveTrain'
			},{
				name: '规章制度',
				icon: 'icon-rule',
				path: '/archiveRule'
			},{
				name: '微型消防站',
				icon: 'icon-fire-control',
				path: '/archiveStation'
			},{
				name: '值班人员',
				icon: 'icon-users',
				path: '/archiveUsers'
			}]
		}
	},
	computed: {
		mainH () {
			return this.winH-180
		}
	},
	watch: {},
	methods: {},
	created () {},
	activated () {},
	mounted () {}
}
</script>
